# Group Speakers Calls
Announcement for call for speaker to accept session proposals from speakers.

| Parameter | Description | Type | Required |
|:----------|-------------|------|----------|
| `announcement`  | Announcement for speakers call | string | **yes** |
| `starts-at` | Start date of the speakers call | ISO 8601 (tz-aware) | **yes** |
| `ends-at` | End date of the speakers call | ISO 8601 (tz-aware) | **yes** |
| `hash` | Hash for speakers call | string | - |
| `privacy` | Privacy of speakers call | string | - |


## Speakers Call Collection [/v1/speakers-calls{?page%5bsize%5d,page%5bnumber%5d,sort,filter}]
+ Parameters
    + page%5bsize%5d (optional, integer, `10`) - Maximum number of resources in a single paginated response.
    + page%5bnumber%5d (optional, integer, `2`) - Page number to fetched for the paginated response.
    + sort (optional, string, `starts-at`) - Sort the resources according to the given attribute in ascending order. Append '-' to sort in descending order.
    + filter (optional, string, `[]`) - Filter according to the flask-rest-jsonapi filtering system. Please refer: http://flask-rest-jsonapi.readthedocs.io/en/latest/filtering.html for more.

### Create Speakers Call [POST]
Create a new speakers call using an event_id.

+ Request (application/vnd.api+json)

    + Headers

            Authorization: JWT <Auth Key>

    + Body

            {
              "data": {
                "relationships":{
                  "event":{
                    "data":{
                      "type":"event",
                      "id":"1"
                    }
                  }
                },
                "attributes": {
                  "announcement": "Speaker Call Announcement",
                  "starts-at": "2017-06-01T01:24:47.500127+00:00",
                  "ends-at": "2017-06-20T01:24:47.500127+00:00",
                  "hash": "hash",
                  "privacy": "public"
                },
                "type": "speakers-call"
              }
            }


+ Response 201 (application/vnd.api+json)

        {
          "data": {
            "relationships": {
              "event": {
                "links": {
                  "self": "/v1/speakers-calls/1/relationships/event",
                  "related": "/v1/speakers-calls/1/event"
                }
              }
            },
            "attributes": {
              "announcement": "Speaker Call Announcement",
              "starts-at": "2017-06-01T01:24:47.500127+00:00",
              "ends-at": "2017-06-20T01:24:47.500127+00:00",
              "deleted-at": null,
              "hash": "hash",
              "privacy": "public"
            },
            "type": "speakers-call",
            "id": "1",
            "links": {
              "self": "/v1/speakers-calls/1"
            }
          },
          "jsonapi": {
            "version": "1.0"
          },
          "links": {
            "self": "/v1/speaker-calls/1"
          }
        }

## Speakers Call Details [/v1/speakers-calls/{speakers_call_id}]

+ Parameters
    + speakers_call_id: 1 (integer) - ID of the session in the form of an integer

### Speakers Call Details [GET]
Get a single speakers call.

+ Request

    + Headers

            Accept: application/vnd.api+json

            Authorization: JWT <Auth Key>

+ Response 200 (application/vnd.api+json)

        {
          "data": {
            "relationships": {
              "event": {
                "links": {
                  "self": "/v1/speakers-calls/1/relationships/event",
                  "related": "/v1/speakers-calls/1/event"
                }
              }
            },
            "attributes": {
              "announcement": "Speaker Call Announcement",
              "starts-at": "2017-06-01T01:24:47.500127+00:00",
              "ends-at": "2017-06-20T01:24:47.500127+00:00",
              "hash": "hash",
              "deleted-at": null,
              "privacy": "public"
            },
            "type": "speakers-call",
            "id": "1",
            "links": {
              "self": "/v1/speakers-calls/1"
            }
          },
          "jsonapi": {
            "version": "1.0"
          },
          "links": {
            "self": "/v1/speakers-calls/1"
          }
        }


### Update Speakers Call [PATCH]
Update a single speakers call by `id`.

+ `id` (integer) - ID of the record to update **(required)**

+ Request (application/vnd.api+json)

    + Headers

            Authorization: JWT <Auth Key>

    + Body

            {
              "data": {
                "attributes": {
                  "announcement": "Speaker Call Announcement",
                  "starts-at": "2017-06-01T01:24:47.500127+00:00",
                  "ends-at": "2017-06-20T01:24:47.500127+00:00",
                  "hash": "hash",
                  "privacy": "public"
                },
                "type": "speakers-call",
                "id": "1"
              }
            }

+ Response 200 (application/vnd.api+json)

            {
                "data": {
                    "relationships": {
                        "event": {
                            "links": {
                                "self": "/v1/speakers-calls/1/relationships/event",
                                "related": "/v1/speakers-calls/1/event"
                            }
                        }
                    },
                    "attributes": {
                        "announcement": "Speaker Call Announcement",
                        "ends-at": "2017-06-20T01:24:47.500127+00:00",
                        "hash": "hash",
                        "starts-at": "2017-06-01T01:24:47.500127+00:00",
                        "deleted-at": null,
                        "privacy": "public"
                    },
                    "type": "speakers-call",
                    "id": "1",
                    "links": {
                        "self": "/v1/speakers-calls/1"
                    }
                },
                "jsonapi": {
                    "version": "1.0"
                },
                "links": {
                    "self": "/v1/speakers-calls/1"
                }
            }

### Delete Speakers Call [DELETE]
Delete a single speakers call.

+ Request

    + Headers

            Accept: application/vnd.api+json

            Authorization: JWT <Auth Key>

+ Response 200 (application/vnd.api+json)

        {
          "meta": {
            "message": "Object successfully deleted"
          },
          "jsonapi": {
            "version": "1.0"
          }
        }

## Get Speakers Call for an Event [/v1/events/{event_identifier}/speakers-call]

+ Parameters
    + event_identifier: 1 (string) - identifier or event id of the event. (b8324ae2 is an example of identifier)

### Get Speakers Call Details for an Event [GET]

+ Request

    + Headers

            Accept: application/vnd.api+json

            Authorization: JWT <Auth Key>

+ Response 200 (application/vnd.api+json)


        {
            "data": {
                "relationships": {
                    "event": {
                        "links": {
                            "self": "/v1/speakers-calls/1/relationships/event",
                            "related": "/v1/speakers-calls/1/event"
                        }
                    }
                },
                "attributes": {
                    "announcement": "Speaker Call Announcement",
                    "ends-at": "2017-06-20T01:24:47.500127+00:00",
                    "hash": "hash",
                    "starts-at": "2017-06-01T01:24:47.500127+00:00",
                    "deleted-at": null,
                    "privacy": "public"
                },
                "type": "speakers-call",
                "id": "1",
                "links": {
                    "self": "/v1/speakers-calls/1"
                }
            },
            "jsonapi": {
                "version": "1.0"
            },
            "links": {
                "self": "/v1/speakers-calls/1"
            }
        }
